<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE xsl:stylesheet  [
	<!ENTITY nbsp   "&#160;">
	<!ENTITY copy   "&#169;">
	<!ENTITY reg    "&#174;">
	<!ENTITY trade  "&#8482;">
	<!ENTITY mdash  "&#8212;">
	<!ENTITY ldquo  "&#8220;">
	<!ENTITY rdquo  "&#8221;"> 
	<!ENTITY pound  "&#163;">
	<!ENTITY yen    "&#165;">
	<!ENTITY euro   "&#8364;">
]>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:page="urn:page">
	<xsl:output method="html" encoding="utf-8"/>
	<xsl:param name="rowcount"/>
	<!--数据库总记录数-->
	<xsl:param name="maxrow"/>
	<!--每页记录数-->
	<xsl:param name="curpage"/>
	<!--当前页码-->
	<xsl:param name="param"/>
	<!--引入 param 参数-->
	<xsl:param name="templatename"/>
	<!--Label.xml 模块名称-->
	<xsl:param name="orderby"/>
	<!--Label.xml orderby 参数-->
	<xsl:param name="where"/>
	<!--Label.xml where 参数-->
	<xsl:param name="runtime"/>
	<!--运行时长-->
	<xsl:template match="/">
		<xsl:choose>
		<xsl:when test="$templatename='AUTOID'">
			<input type="hidden"  name="articleid" value="{rows/row/id}"/>
			<input type="hidden" id="channelguid"  name="channelguid" value="{page:xRequest('guid')}"/>
			<input type="hidden" id="url"  name="url" value="{rows/row/url}"/>
		</xsl:when>
		<xsl:when test="$templatename='文章列表标题'">
			<div class="title">
				<h3><xsl:value-of select="rows/row/f_name"/></h3>
				<ul>
					<li class="b">录入:<a href="edit.html?guid={page:xRequest('guid')}">新文章</a><a href="editOld.html?guid={page:xRequest('guid')}">旧文章</a><!--<a href="editTopic.html?guid={page:xRequest('guid')}">专题文章</a>--></li>
					<li>|</li>
					<li><a href="/channel/edit.html?id={rows/row/id}">栏目管理</a><a href="/channel/publish.html?guid={page:xRequest('guid')}">发布管理</a><a href="{rows/row/f_demopath}" target="_blank">栏目预览</a><a href="###" id="btnTreeSearch" rel="{rows/row/f_name}">[定位]</a></li>
					<!--<li><a href="#">更多</a></li>-->
				</ul>
			</div>
		</xsl:when>
		<xsl:when test="$templatename='文章查看标题'">
			<div class="title">
				<h3><xsl:value-of select="rows/row/f_name"/></h3>
				<ul>
					<li class="b">录入:<a href="edit.html?guid={page:xRequest('guid')}">新文章</a><a href="editOld.html?guid={page:xRequest('guid')}">旧文章</a><!--<a href="editTopic.html?guid={page:xRequest('guid')}">专题文章</a>--></li>
					<li>|</li>
					<li><a href="/channel/edit.html?id={rows/row/id}">栏目管理</a><a href="{rows/row/f_demopath}" target="_blank">栏目预览</a><a href="list.html?guid={rows/row/f_guid}">文章列表</a> <a href="###" id="titleGoBack">返回</a></li>
					<!--<li><a href="#">更多</a></li>-->
				</ul>
			</div>
		</xsl:when>
		<xsl:when test="$templatename='文章编辑标题'">
			<div class="title">
				<h3><xsl:value-of select="rows/row/f_name"/></h3>
				<ul>
					<li><a href="###" id="titleGoBack">返回</a></li>
				</ul>
			</div>
		</xsl:when>
		<xsl:when test="$templatename='TopSetList'">
		<table width="100%" border="0" cellspacing="1" cellpadding="0">
				<thead>
					<tr>
						<td>编号</td>
						<td>选择</td>
						<td>状态</td>
						<td>标题</td>
						<td>套红</td>
						<td>视频</td>
						<td>栏目</td>
						<td>加入时间</td>
						<td>录入者</td>
						<td>操作</td>
					</tr>
				</thead>
				<tbody>
					<xsl:for-each select="rows/row">
					<tr class="{page:xIIF(position() mod 2 =1,'','odd')}"><!--激活时色彩-->
						<td><xsl:value-of select="id"/></td>
						<td><input name="id" type="checkbox" class="checkbox" value="{id}" /></td>
						<td><xsl:choose>
							<xsl:when test="f_issuestatus=0">
							初稿
							</xsl:when>
							<xsl:when test="f_issuestatus=1">
							已编
							</xsl:when>
							<xsl:when test="f_issuestatus=10">
							已审
							</xsl:when>
							<xsl:when test="f_issuestatus=15">
							已签
							</xsl:when>
							<xsl:when test="f_issuestatus=20">
							已发
							</xsl:when>
							<xsl:otherwise>
							未知
							</xsl:otherwise>
							</xsl:choose></td>
						<td style="{page:xIIF(f_isred=1,'color:red','')}"><xsl:value-of select="f_title"/></td>
						<td><input name="isred" type="checkbox" class="checkbox" value="1"><xsl:if test="f_isred=1"><xsl:attribute name="checked">1</xsl:attribute></xsl:if></input></td>
						<td><input name="isvideo" type="checkbox" class="checkbox" value="1"><xsl:if test="f_isvideo=1"><xsl:attribute name="checked">1</xsl:attribute></xsl:if></input></td>
						<td><xsl:value-of select="f_channel_name"/></td>
						<td class="gray"><xsl:value-of select="substring(f_addtime,1,19)"/></td>
						<td class="gray"><xsl:value-of select="f_addmastername"/></td>
						<td><!--<a href="###" class="btnUpdate">更新</a>--><a href="###" class="btnDelete" rel="{id}">删除</a></td>
					</tr>
					</xsl:for-each>
					<tr>
						<td colspan="13"><dl class="operation">
								<dt>
									<label>
										<input type="checkbox" class="checkbox" value="id"  id="allselect"/>
										全选</label>
								</dt>
								<dd><a href="###" id="batchDelete">删除</a></dd>
							</dl></td>
					</tr>
				</tbody>
			</table>
		</xsl:when>
		<xsl:when test="$templatename='channelParent'">
			<xsl:for-each select="rows/row">
				<option value="{id}"><xsl:value-of select="f_name"/></option>
			</xsl:for-each>
		</xsl:when>
		<xsl:when test="$templatename='Getchannel'">
			<xsl:if test="count(rows/row)=0">0,无此栏目</xsl:if>
			<xsl:if test="count(rows/row)!=0">1,<xsl:value-of select="rows/row/id"/></xsl:if>
		</xsl:when>
		<xsl:when test="$templatename='channelSelect'">[
		<xsl:for-each select="rows/row">
		{"label":"<xsl:value-of select="f_name"/>","value":"<xsl:value-of select="id"/>"}
		<xsl:if test="position()!=last()">,</xsl:if>
		</xsl:for-each>
		]</xsl:when>
		<xsl:when test="$templatename='NewhouseSelect'">[
		<xsl:for-each select="rows/row">
		{"label":"<xsl:value-of select="F_Name"/>","value":"<xsl:value-of select="ID"/>"}
		<xsl:if test="position()!=last()">,</xsl:if>
		</xsl:for-each>
		]</xsl:when>
		<xsl:when test="$templatename='读取联系人'">
		<xsl:for-each select="rows/row">
			<li class="ui-widget-content ui-corner-tr">
				
				<h5 class="ui-widget-header"> <xsl:value-of select="f_companyname"/>  &nbsp;<span><xsl:value-of select="f_fullname"/></span>
				</h5>
				<span class="address">
				<xsl:if test="page:xRequest('type',1)=1"><xsl:value-of select="f_email"/>
				</xsl:if>
				<xsl:if test="page:xRequest('type',1)=2"><xsl:value-of select="f_mobile"/>
				</xsl:if>	
				</span>
				<span class="ui-icon ui-icon-circle-plus fr" style="margin-top:3px;">&nbsp;</span>
				<input name="address" type="hidden" value="{page:xIIF(page:xRequest('type',1)=1,f_email,f_mobile)}"/>	
			</li>
		</xsl:for-each>
		</xsl:when>
		</xsl:choose>
	</xsl:template>
</xsl:stylesheet>